package com.navinfo.opentsp.qingqi.trackoptimize.configuration;

import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.authority.SimpleGrantedAuthority;

/**
 * list of default granted authorities
 */
public final class Authorities {

    private Authorities() {
    }
    
    public static final String ADMIN_ROLE = "ROLE_ADMIN";
    public static final String USER_ROLE = "ROLE_USER";
    public static final String CONSUMER_ROLE = "ROLE_CONSUMER";
    
    public static final GrantedAuthority ADMIN_AUTHORITY = new SimpleGrantedAuthority(ADMIN_ROLE);
    public static final GrantedAuthority USER_AUTHORITY = new SimpleGrantedAuthority(USER_ROLE);
    public static final GrantedAuthority CONSUMER_AUTHORITY = new SimpleGrantedAuthority(CONSUMER_ROLE);
}
